#ifndef __GLES2TextureManager_H__
#define __GLES2TextureManager_H__

#include "TextureManager.h"
#include "GLES2Texture.h"
#include "GLES2Support.h"

namespace PVM
{
	class GLES2TextureManager : public TextureManager
	{
	public:
		GLES2TextureManager(GLES2Support& support);
		virtual ~GLES2TextureManager();
		
		GLuint getWarningTextureID() {return mWarningTextureID;}
		
		PixelFormat getNativeFormat(TextureType ttype, PixelFormat format, int usage);
		bool isHardwareFilteringSupported(TextureType ttype, PixelFormat format, int usage,
										  bool preciseFormatOnly = false);
		
	protected:
		Resource* createImpl(const std::string& name, ResourceHandle handle,
							 const std::string& group, bool isManual, ManualResourceLoader* loader,
							 const NameValuePairList* createParams);
		void createWarningTexture();
		
		GLES2Support& mGLSupport;
		GLuint mWarningTextureID;
	};
}

#endif
